c# reading months as int

51

c# reading months as int -

int month = DateTime.ParseExact(MonthNameStr, "MMMM", CultureInfo.CurrentCulture ).Month

c# reading months as int -

int  month = DateTimeFormatInfo.CurrentInfo.MonthNames.ToList().IndexOf(MonthNameStr) + 1;

Comments

Submit
0 Comments